<script type="text/javascript">
 function checkLogin()
 {
     alert('您还没有登陆');
     return false;
 }
</script>
<div id="indexcates">
        <?php
                global $db;
                $teacher_id = $_GET['teacher_id'];
                $sql = "select * from nettteach_member where id = ".$teacher_id;
                $result_teacher = $db -> query($sql);
                if($row_teacher=$db->fetch_array($result_teacher)){

        ?>
        <div class="span9">
        <div class="row-fluid" style="margin-top:10px;">
            <ul class="breadcrumb">
                <li><a href="#"><?php echo ($row_teacher['realname'])?>&nbsp;老师的视频 </a> </li>
            </ul>
        </div>			
        <div id="01">
            <div class="row-fluid">
        <?php
                        $sql_videos = "select * from nettteach_videos where belonger = '".$teacher_id."'and state ='0' order by intotime  ";
                        $result_videos = $db -> query($sql_videos);
                        while($row_videos=$db->fetch_array($result_videos)){
        ?>
                <div class="span4" title="<?php echo($row_videos['title'])?>">
                        缩略图:<br><img width="70px" height="60px" src="<?php if($row_videos['photo']!=''){ echo("teacher/".$row_videos['photo']);}else{echo("teacher/uploadfiles/image/1209030235119905.jpg");}?>"  border="0" alt="">
                        <p>视频：<?php echo(sub_str($row_videos['title'], 11))?></p>  			
                        <p>点击数：<?php echo($row_videos['times'])?></p>
                        <p>更新时间：<?php echo(date('Y-m-d',$row_videos['intotime']))?></p>
                        <p><a title="<?php echo($row_videos['title'])?>" class="btn btn-info" href="?do=viewvideos&video_id=<?php echo($row_videos['id'])?>" <?php if($_SESSION['sid']==''){ ?> onclick="return checkLogin()" <?php }?> >进入 »</a></p>
                </div><!--/span-->
                <?php 
                        }
                }
                ?>
            </div><!--/row-->
        </div>

</div>
</div>
